package com.itheima.web;

import com.itheima.service.GoodsService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
public class GoodsController {

    @Resource
    private GoodsService goodsService;

    @GetMapping("/deduckStore/{goodId}/{num}")
    public boolean deduckStore(@PathVariable("goodId") Long goodId,@PathVariable("num") Integer num){
        return goodsService.deduckStore(goodId,num);
    }

}
